extends RigidBody2D

signal on_character_above(blockPosY)

signal on_block_visibility_exit(blockName, blockPosY)

# Declare member variables here. Examples:
# var a = 2
# var b = "text"


# Called when the node enters the scene tree for the first time.
func _ready():
	pass # Replace with function body.


# Called every frame. 'delta' is the elapsed time since the previous frame.
#func _process(delta):
#	pass


func _on_Area2D_body_entered(body):
	print(body.name)
	if "Character" == body.name:
		emit_signal("on_character_above", position.y)


func _on_VisibilityNotifier2D_viewport_exited(viewport):
	emit_signal("on_block_visibility_exit", self.name, position.y)
